package com.hmsproject.datastructures.event;

import java.util.Date;

public class EventSchedule {

	public EventSchedule(Date fromDate, Date toDate){
		this.fromDate = fromDate;
		this.toDate = toDate;
	}
	
	
	public Date getFromDate() {
		return fromDate;
	}
	public void setFromDate(Date fromDate) {
		this.fromDate = fromDate;
	}
	public Date getToDate() {
		return toDate;
	}
	public void setToDate(Date toDate) {
		this.toDate = toDate;
	}
	private Date fromDate;
	private Date toDate;
	
	@Override
	public boolean equals(Object schedule){
		
		EventSchedule sch = (EventSchedule)schedule;
		return this.fromDate.equals(sch.fromDate) && this.toDate.equals(sch.toDate);
	}
	
	@Override
	public int hashCode(){
		return fromDate.hashCode() + toDate.hashCode();
	}
	
	@Override
	public String toString() {
		return super.toString();
	}
}
